<script type="text/javascript">
  $(window).scroll(function () {
      var windowTop = $(window).scrollTop();
      if (windowTop > 130) {
          $(".nav").addClass("nav_fix");
      } else {
          $(".nav").removeClass("nav_fix");
      }
  })
  function copywx() {
      var val = document.getElementById('target');
      window.getSelection().selectAllChildren(val);
      document.execCommand("Copy");
      window.location.href='weixin://';
  }
</script>
<script>
    layui.use(['carousel', 'form'], function(){
        var carousel = layui.carousel //轮播
        //执行一个轮播实例
        carousel.render({
            elem: '#test1'
            ,width: '100%' //设置容器宽度
            ,height: 200
            ,arrow: 'none' //不显示箭头
            ,anim: 'fade' //切换动画方式
        });
    });
</script>